package chapter03
import org.apache.spark.{SparkConf, SparkContext}
object Test05_Map {
  def main(args: Array[String]): Unit = {
    //map算子
    val conf = new SparkConf().setMaster("local[*]").setAppName("map")
    val sc = new SparkContext(conf)
    //新建一个RDD
    val value = sc.makeRDD(List(1, 2, 3, 4, 5, 6))
    //map算子
    val value1 = value.map(e => {
      e + 1
    })
    println(value1.collect().toList)
  }
}
